<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
		<link rel="stylesheet" href="/0423/project/tpcms/Application/Admin/View/public/css/public.css" />
		<script type="text/javascript" src="/0423/project/tpcms/Application/Admin/View/public/js/jquery-1.7.2.min.js"></script>
		<script type="text/javascript" src="/0423/project/tpcms/Application/Admin/View/public/js/public.js"></script>
       <!-- 配置文件 -->
    <script type="text/javascript" src="/0423/project/tpcms/static//ueditor/ueditor.config.js"></script>
    <!-- 编辑器源码文件 -->
    <script type="text/javascript" src="/0423/project/tpcms/static//ueditor/ueditor.all.min.js"></script>
	<script type="text/javascript" src="/0423/project/tpcms/static//uploadify/jquery.uploadify.min.js"></script>
    <link href="/0423/project/tpcms/static//uploadify/uploadify.css" type="text/css" rel="stylesheet"></link>
	<title>发布内容</title>

</head>
<body>
	<form action="" method="post" enctype="multipart/form-data" method="post" >

	
		<table class="table">
			<tr >
				<td class="th" colspan="2">添加内容</td>
			</tr>
			<tr>
				<td>当前所属栏目</td>
				<td>
					<span class="tdLtitle8" style="padding:8px;"><?php echo ($modelField["name"]); ?></span>	

				</td>
			</tr>
			<tr>
				<td>标题</td>
				<td><input type="text" name="atitle" class="tdLtitle8"/></td>
			</tr>
			<tr>
				<td>副标题</td>
				<td><input type="text" name="asubtitle" class="tdLtitle8"/></td>
			</tr>
			<tr>
				<td>置顶信息</td>
				<td><input class='np' type='checkbox' name='aattr[]' id='aattrh' value='h'>头条[h]<input class='np' type='checkbox' name='aattr[]' id='aattrc' value='c'>推荐[c]<input class='np' type='checkbox' name='aattr[]' id='aattrf' value='f'>幻灯[f]<input class='np' type='checkbox' name='aattr[]' id='aattra' value='a'>特荐[a]<input class='np' type='checkbox' name='aattr[]' id='aattrs' value='s'>滚动[s]<input class='np' type='checkbox' name='aattr[]' id='aattrb' value='b'>加粗[b]<input class='np' type='checkbox' name='aattr[]' id='aattrp' value='p'>图片[p]<input class='np' type='checkbox' name='aattr[]' id='aattrj' value='j' onclick='ShowUrlTr()'>跳转[j]            </td>
       </td>
			</tr>
			<tr>
				<td>文章来源</td>
				<td><input type="text" name="asource" class="tdLtitle8"/></td>
			</tr>
			<tr>
				<td>关键字</td>
				<td><input type="text" name="akeywords" class="tdLtitle8"/></td>
			</tr>
			<tr>
				<td>TAG标签</td>
				<td><input type="text" name="content_rule" class="tdLtitle8"/>(多个标签用','号分开，单个标签小于12字节)</td>
			</tr>

            
           
            <tr class="tab1">
                <th class="w100">无刷新上传</th>
                <td>
                  <div lab="uploadFile">
                <input id="listIMg" type="file" name="" multiple="true">
                <span>类型: *.jpg 大小: 2000KB 数量: 5</span>
                <script type="text/javascript">
                    $(function() {
                        $('#listIMg').uploadify({
                            'formData'     : {	//POST数据
                                'session_id' : '<?php echo session_id(); ?>',
                            },
                            'fileTypeDesc' : '上传文件',//上传描述
                            'fileTypeExts' : '*.jpg',
                            'swf'      : '/0423/project/tpcms/static/uploadify/uploadify.swf',
                            'uploader' : '<?php echo U('Admin/content/uploadImg','','',true);?>',
                            'buttonText':'选择文件',
                            'fileSizeLimit' : '3000KB',
                            'uploadLimit' : 1000,//上传文件数
                            'width':65,
                            'debug':true,
                            'height':25,
                            'successTimeout':10,//等待服务器响应时间
                            'removeTimeout' : 0.2,//成功显示时间
                            'onUploadSuccess' : function(file, data, response) {
                            	alert(data);alert(response);
                                data=$.parseJSON(data);alert(data);
                                var imageUrl = data.image?data.url:'/0423/project/tpcms/static//image/default.png';
                                var li="<li path='"+data.path+"' url='"+data.url+"'><img src='"+imageUrl+"' class='hd-w80 hd-h70' /><div class='hiddenli'><span class='look'>查看</span><span class='del' >删除</span><span class='imgshow'><img /><span class='close'></span></span></div></li>";
                                $(".showGoosListIMg").prepend(li);
                                $('#inputHidden').append('<li>'+data.goods_info_smallIMg+'</li>');
                                //获取图片域值
                               var smallIMg =  $('#goods_info_smallIMg').val();
                                   $('#goods_info_smallIMg').val(smallIMg+','+data.goods_info_smallIMg);
                            }
                        });
                    });
                </script>
                	<!--异步隐藏内容-->
                	<div id='inputHidden' style="display:none;">
                		
                	</div>
                </td>
                
            </tr>
            
            <tr>
                <td class="w100">列表图预览</td>
                <td class='showGoosListIMg' width="650">  </td>
            </tr>
            

			<tr>
				<td>文章摘要</td>
				<td><textarea name="adigest" id="" cols="50" rows="6"></textarea></td>
			</tr>
			
		<?php echo ($str); ?>
			<tr>
				<td>文章摘要</td>
				<td >
					<input type="file" name="imgtest" />					
				</td>
			</tr>
			<tr>
				<td colspan="2">
					<input type="submit" value="添加" class="input_button"/>
					
				</td>
			</tr>

		</table>
	</form>
</body>
</html>